import tkinter as tk
import tkinter.font as tkFont
import tkinter.messagebox as tkMsgBox

fpx = 10
fpy = 10

"""放大字体"""
top = tk.Tk()
top.resizable(False, False)

defaultFont = tkFont.Font(top, size = 20)

userFrame= tk.Frame(top)
userFrame.pack(side = tk.TOP, fill=tk.X, padx = fpx, pady=fpy)
userLabel = tk.Label(userFrame, text='用户名:', width=8, anchor=tk.E, font=defaultFont)
userLabel.pack(side=tk.LEFT)


userEntry = tk.Entry(userFrame, width=20, font=defaultFont)
userEntry.pack(side=tk.LEFT)

pwdFrame= tk.Frame(top)
pwdFrame.pack(side=tk.TOP, fill=tk.X, padx = fpx, pady=fpy)
pwdLabel = tk.Label(pwdFrame, text='密码:', width=8, anchor=tk.E, font=defaultFont)
pwdLabel.pack(side=tk.LEFT)


pwdEntry = tk.Entry(pwdFrame, width=20, font=defaultFont)
pwdEntry.pack(side=tk.LEFT)

btnFrame = tk.Frame(top)
btnFrame.pack(side=tk.TOP, fill=tk.X, padx=fpx, pady=fpy)

confirmBtn = tk.Button(btnFrame, width=8, text='确认', font=defaultFont)
confirmBtn.pack(side=tk.TOP)

top.mainloop()